def jinzhi_10_2(input_num):
    """
    10进制转2进制
    :param input_num:
    :return:
    """
    if input_num <= 1:
        return [input_num]
    else:
        result = []
        while input_num:
            input_num, y = divmod(input_num, 2)
            result.append(y)
        return result[::-1]


input_num = 7
j = jinzhi_10_2(input_num)
for i in j:
    print(i, end="")

print()
print(bin(input_num))
